package com.ruoyi.food.domain;

import com.alibaba.fastjson.annotation.JSONField;
import com.alibaba.fastjson.serializer.ToStringSerializer;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;
import com.ruoyi.system.api.domain.SysFile;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;
import java.util.List;


/**
 * 园区食品安全档案对象 opm_food_safe_file
 *
 * @author cjie
 * @date 2021-07-24
 */
@Data
@ApiModel
public class OpmFoodSafeFile extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 序号 */
    @ApiModelProperty(value = "序号")
    @JsonSerialize(using = com.fasterxml.jackson.databind.ser.std.ToStringSerializer.class)
    @JSONField(serializeUsing= ToStringSerializer.class)
    private Long id;

    /** 食品名称 */
    @Excel(name = "食品名称")
    @ApiModelProperty(value = "食品名称")
    private String name;

    /** 卫生许可证 */
    @Excel(name = "卫生许可证")
    @ApiModelProperty(value = "卫生许可证")
    private String license;

    /** 生产日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "生产日期", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "生产日期")
    private Date productDate;

    /** 保质期限 */
    @Excel(name = "保质期限")
    @ApiModelProperty(value = "保质期限")
    private String life;

    /** 保存条件 */
    @Excel(name = "保存条件")
    @ApiModelProperty(value = "保存条件")
    private String storage;

    /** 合格证 */
    @Excel(name = "合格证")
    @ApiModelProperty(value = "合格证")
    private String certificate;

    /** 附件数量 */
    @Excel(name = "附件数量")
    @ApiModelProperty(value = "附件数量")
    private Integer attachNum;

    /** 质检报告 */
    @Excel(name = "质检报告")
    @ApiModelProperty(value = "质检报告")
    private String inspectReport;

    /** 附件 */
    @Excel(name = "附件")
    @ApiModelProperty(value = "附件")
    private String url;

    /** 附件id集合 */
    @Excel(name = "附件id集合")
    @ApiModelProperty(value = "附件id集合")
    private List<Long> fileIdList;

    /** 附件集合 */
    @Excel(name = "附件集合")
    @ApiModelProperty(value = "附件集合")
    private List<SysFile> fileList;

}
